import 'package:flutterproject/generated/json/base/json_convert_content.dart';
import 'package:flutterproject/page/mine/children/order/data/order_list_bean.dart';

OrderListBean $OrderListBeanFromJson(Map<String, dynamic> json) {
	final OrderListBean orderListBean = OrderListBean();
	final int? last = jsonConvert.convert<int>(json['last']);
	if (last != null) {
		orderListBean.last = last;
	}
	final List<OrderListList>? list = jsonConvert.convertListNotNull<OrderListList>(json['list']);
	if (list != null) {
		orderListBean.list = list;
	}
	return orderListBean;
}

Map<String, dynamic> $OrderListBeanToJson(OrderListBean entity) {
	final Map<String, dynamic> data = <String, dynamic>{};
	data['last'] = entity.last;
	data['list'] =  entity.list?.map((v) => v.toJson()).toList();
	return data;
}

OrderListList $OrderListListFromJson(Map<String, dynamic> json) {
	final OrderListList orderListList = OrderListList();
	final int? id = jsonConvert.convert<int>(json['id']);
	if (id != null) {
		orderListList.id = id;
	}
	final int? createTime = jsonConvert.convert<int>(json['createTime']);
	if (createTime != null) {
		orderListList.createTime = createTime;
	}
	final String? orderNo = jsonConvert.convert<String>(json['orderNo']);
	if (orderNo != null) {
		orderListList.orderNo = orderNo;
	}
	final String? totalAmount = jsonConvert.convert<String>(json['totalAmount']);
	if (totalAmount != null) {
		orderListList.totalAmount = totalAmount;
	}
	final int? state = jsonConvert.convert<int>(json['state']);
	if (state != null) {
		orderListList.state = state;
	}
	final int? productId = jsonConvert.convert<int>(json['productId']);
	if (productId != null) {
		orderListList.productId = productId;
	}
	final String? productTag = jsonConvert.convert<String>(json['productTag']);
	if (productTag != null) {
		orderListList.productTag = productTag;
	}
	final String? productName = jsonConvert.convert<String>(json['productName']);
	if (productName != null) {
		orderListList.productName = productName;
	}
	final int? productNum = jsonConvert.convert<int>(json['productNum']);
	if (productNum != null) {
		orderListList.productNum = productNum;
	}
	final String? productDescription = jsonConvert.convert<String>(json['productDescription']);
	if (productDescription != null) {
		orderListList.productDescription = productDescription;
	}
	return orderListList;
}

Map<String, dynamic> $OrderListListToJson(OrderListList entity) {
	final Map<String, dynamic> data = <String, dynamic>{};
	data['id'] = entity.id;
	data['createTime'] = entity.createTime;
	data['orderNo'] = entity.orderNo;
	data['totalAmount'] = entity.totalAmount;
	data['state'] = entity.state;
	data['productId'] = entity.productId;
	data['productTag'] = entity.productTag;
	data['productName'] = entity.productName;
	data['productNum'] = entity.productNum;
	data['productDescription'] = entity.productDescription;
	return data;
}